{{ if and (not .IsHome) .Content }}
{{ $section := default .Section ($.Scratch.Get "section") }}
<li class="pattern">&nbsp;&nbsp;</li>
{{ with .Site.Params.githubContentURL }}
{{ $.Scratch.Set "filePath" $.File.Path }}
{{ if in $.File.Path ".html"}}
{{ $.Scratch.Set "filePath" (replaceRE "[.]html$" ".Rmd" $.File.Path) }}
{{ $.Scratch.Set "filePath" (replace ($.Scratch.Get "filePath") "\\/" "/") }}
{{ end }}
<li class="pattern"><a href="{{ or $.Params.githubEditURL  (print .  ($.Scratch.Get "filePath")) }}" target="_blank">{{ default "编辑" (index $.Site.Params.lang.edit $section) }}</a></li>
{{ end }}
{{ with .Section }}
<li class="pattern"><a href="/{{ . }}/index.xml" type="application/rss+xml" title="RSS feed">{{ default "订阅" (index $.Site.Params.lang.subscribe $section) }}</a></li>
{{ end }}
<li class="pattern"><a href="/license/" title="License">{{ default "版权" (index $.Site.Params.lang.license $section) }}</a></li>
{{ end }}
